/****************************************************
          File Name:6-3.cpp
          Author: Abby Cin
          Mail: abbytsing@gmail.com
          Created Time: Thu 18 Dec 2014 09:15:37 PM CST
*****************************************************/

#include<iostream>
using namespace std;

int main()
{
    char ans;
    bool exit = false;

    cout << "Please enter one of the folloeing choices:\n"
        << "c) carnivore\t\tp) pianist\n"
        << "t) tree\t\t\tg) game\n";

    for(;;)
    {
        if(exit)
            break;

        cin >> ans;

        switch(ans)
        {
            case 'c':
                cout << "A maple is a carnivore "<< endl;
                exit = true;
                break;
            case 'p':
                cout << "A maple is a pianist" << endl;
                exit = true;
                break;
            case 't':
                cout << "A maple is a ree "<< endl;
                exit = true;
                break;
            case 'g':
                cout << "A maple is a game"<< endl;
                exit = true;
                break;
            default:
                cout << "Please enter c, p, g or t: ";
                break;
        }
    }

    return 0;
}
